﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace DataStructures
{
	public enum TraversalType : int
	{
		TopDownLeftToRight,
		TopDownRightToLeft,
		BottomUpLeftToRight,
		BottomUpRightToLeft,
		PreOrder,
		InOrder,
		PostOrder
	}
	public interface IBaseTree<Element, Tree, TreeList>
		where Tree : IBaseTree<Element, Tree, TreeList>
		where TreeList : IBaseTreeList<Element, Tree, TreeList>
	{
		bool HasParent { get; }
		bool HasChildren { get; }
		Tree Parent { get; set; }
		Tree Root { get; }
		TreeList Children { get; }
		Element Value { get; set; }
		TraversalType TraversalType { get; set; }
		int Depth { get; }
		int Leaves { get; }
		IBaseEnumerable<Element, Tree, TreeList, Tree> Trees { get; }
		IBaseEnumerable<Element, Tree, TreeList, Element> Elements { get; }
		void Clear();
	}
}
